﻿<?php
    $url = 'http://bikeshopadmin.olbike.com/V3/?service=Active.GetBaseInfo';

    $ch = curl_init();  //开启curl
    curl_setopt($ch, CURLOPT_URL, $url);  //curl请求地址
    curl_setopt($ch, CURLOPT_POST, 1);   //请求一个正规的HTTP POST请求, 第三个参数要非零
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);   //默认0是直接将信息显示在浏览器中,设为1表示就能取值
    curl_setopt($ch, CURLOPT_HEADER,0);  //如果成功,请求头信息不显示, 1就显示
    curl_setopt($ch, CURLOPT_POSTFIELDS, $data);  //使用POST方法请求
    $buf = curl_exec($ch);    //抓取URL并把它传递给浏览器
    $newBuf = json_decode($buf,true);
?>
<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8" />
	<title>直播首页</title>
	<link href="source/plugin/zhibo/static/style/reset_css.css" rel="stylesheet" />
    <link rel="stylesheet"  href="source/plugin/zhibo/static/style/font/iconfont.css">
	<link href="source/plugin/zhibo/static/style/all.css" rel="stylesheet" />
    <!--[if lt IE 9]>  
        <script language="javascript" type="text/javascript" src="source/plugin/zhibo/static/js/respond.src.js"></script>
        <script language="javascript" type="text/javascript" src="source/plugin/zhibo/static/js/html5.js"></script>
    <![endif]-->
</head>
<body>
	<div id="VideoBanner">
                        <div class="focusbox">
                            <div id="fullbanner">
                                <div class="wrappic">
                                    <ul>
                                        <?php foreach($newBuf['data']['hotData'] as $v) {?>
                                        <li class="plan">
                                            <a href="plugin.php?id=zhibo&ac=activity&op=view&identify=<?php echo $v['id']?>" target="_blank">
                                                <img width="905" height="560" src="<?php echo $v['logo'] ?>"  />
                                            </a>
                                        </li>
                                        <?php }?>
                                    </ul>
                                </div>

                                <div class="helper">
                                    <div class="mask-left"></div>
                                    <div class="mask-right"></div>
                                    <a href="javascript:void();" class="prev arrow-left"></a>
                                    <a href="javascript:void();" class="next arrow-right"></a>
                                </div>
                            </div>
                        </div>
                        

	</div>
	<!-- VideoBanner结束 -->

	<section id="VideoList">
    	<div class="center">
			<h3 class="PartTitle"><img src="source/plugin/zhibo/static/images/icon_video.png" > 推荐直播</h3>
            
            <div class="VideoList_nr">
                    <?php foreach($newBuf['data']['homeData'] as $v2){ ?>
                        <div class="Video_">
                                <img class="photo" src="<?php echo $v2['logo'] ?>" alt="description " />
                                <strong><a href="#"><?php echo $v2['channelName']?> </a></strong>
                                <ins>12,275感兴趣 </ins>
                                <time><span class="icon_time"> </span> <?php echo $v2['activeTime']?></time>
                                <a href="plugin.php?id=zhibo&ac=activity&op=view&identify=<?php echo $v2['id']?>" class="btn_play"><i class="iconfont icon-bofang1"></i></a>
                        </div>
                    <?php }?>

                        <span class="clear"></span>
            </div>
            <!-- .VideoList_nr结束 -->
            
<!--			<div class="pages">-->
<!--				<a href="#" class="change">1</a> <a href="#">2</a> <a href="#">3</a> <a href="#">4</a> -->
<!--                <a href="#">5</a> <a href="#">6</a> <a href="#">7</a> ...  <a href="#">99</a> -->
<!--                 <a href="#">100</a>  <a href="#">&gt;</a> &nbsp; &nbsp; 跳转到 <input name="txt" type="text" class="text" /> -->
<!-- <button class="btn" type="button">GO</button>-->
<!--			</div>-->
        
        
        </div>
        
        
	</section>
	<!-- VideoList结束 -->
	<script src="source/plugin/zhibo/static/js/jquery.js"></script>
	<script src="source/plugin/zhibo/static/js/jquery.foucs.js"></script>
	<script src="source/plugin/zhibo/static/js/load.js"></script>

</body>
</html>








